#pragma once
#include "arrow/arrow.h"
#include <string>

namespace ArrowWebCodeView
{
namespace SessionMachine
{

// 枚举对应的字符串就是对应的命令字符串，例如 MsgEnum::Login 对应的字符串就是 "Login" [zhuyb 2024-06-12 18:02:21]
enum class MsgEnum
{
    Start = 0,
    Login,
    Path,
    Folder,
    File,
    End,
};
using MsgEnumStr = Arrow::EnumListToStr<MsgEnum, MsgEnum::Start, MsgEnum::End>;

enum class StateEnum
{
    Start = 0,
    CheckPassword,
    RecvPath,
    SendPathList,
    SendFileData,
    End,
};
using StateEnumStr = Arrow::EnumListToStr<StateEnum, StateEnum::Start, StateEnum::End>;

struct Data
{
    std::string strPassword;
    std::string strDefaultPath;
};

using StateBase = Arrow::Pattern::StateBase2<Data, StateEnum, MsgEnum, const std::string&, std::string&>;
}

}; // namespace ArrowWebCodeView